package br.ufpe.cin.imlm2.jbeat.paths;

import br.ufpe.cin.imlm2.jbeat.model.LightWeightClass;
import br.ufpe.cin.imlm2.jbeat.model.LightWeightMethod;
import br.ufpe.cin.imlm2.util.path.EmptyPathException;
import br.ufpe.cin.imlm2.util.path.Path;

public interface ExceptionPath extends Path<LightWeightMethod> {

	/**
	 * Get the exception propagated in this path.
	 * @return
	 */
	public abstract LightWeightClass getException();
	
	/**
	 * Return true if the starting point of this path generated the exception, i.e.
	 *  the exception was either explicitly thrown or raised by a runtime instruction.
	 * @return
	 */
	public abstract boolean isComplete();
	
	
	/**
	 * Returns the raise site of the exception propagated in this path.
	 * For incomplete paths the starting point may not be the method where the exception was raised
	 * or generated by the runtime.
	 */
	@Override
	public LightWeightMethod getStartingPoint() throws EmptyPathException;
}
